package com.jyxd.web.data.czhisdata;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.annotations.GenericGenerator;

import javax.persistence.*;
import java.io.Serializable;
import java.util.Date;

/**
 * 标本信息表
 */
@Entity
@Table(name = "table_specimen")
@Data
public class Specimen implements Serializable {

    /**
     * 序列
     */
    private static final long serialVersionUID = 1L;

    /**
     * 主键ID
     */
    @ApiModelProperty("主键ID")
    @Id
    @Column(name = "id", length = 32, nullable = false)
    @GeneratedValue(generator="system-uuid")
    @GenericGenerator(name = "system-uuid", strategy = "uuid.hex")
    private String id;


    /**
     * 标本号
     */
    @Column(name = "specimen_no")
    private String specimenNo;

    /**
     * 标本类型
     */
    @Column(name = "specimen_type")
    private String specimenType;

    /**
     * 标本状态
     */
    @Column(name = "specimen_status")
    private String specimenStatus;

    /**
     * 标本来源部位
     */
    @Column(name = "specimen_source_site")
    private String specimenSourceSite;

    /**
     * 送检组织数量
     */
    @Column(name = "specimen_source_amount")
    private String specimenSourceAmount;

    /**
     * 检验：标本收集来源子部位明细
     * 检查：检查子部位
     * 病理：取材部位
     */
    @Column(name = "specimen_collection_site")
    private String specimenCollectionSite;

    /**
     * 标本采集注意事项
     */
    @Column(name = "specimen_description")
    private String specimenDescription;

    /**
     * 采样时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @Column(name = "specimen_collection_dT")
    private Date specimenCollectionDT;

    /**
     * 样本接收时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @Column(name = "specimen_receive_dT")
    private Date specimenReceiveDT;

    /**
     * 标本收集方法
     */
    @Column(name = "specimen_collection_method")
    private String specimenCollectionMethod;

    /**
     * 关联表主键id
     */
    @ApiModelProperty("关联表主键id")
    @Column(name = "re_table_id")
    private String reTableId;


    /**
     * 创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @Column(name = "creat_time")
    private Date creatTime;

}
